package cn.mysocketnet.a06tcpdemo2;

import java.io.OutputStream;
import java.net.Socket;

public class Client {
    public static void main(String[] args) {
        try(Socket socket = new Socket("127.0.0.1", 10001)){
            OutputStream os = socket.getOutputStream();
            os.write("吊毛123".getBytes());
            // BufferedWriter bw = new BufferedWriter(new OutputStreamWriter(os));
            // bw.write("吊毛");
            // bw.newLine();
        }catch (Exception e){
            e.printStackTrace();
        }
    }
}
